Anti-knocking control in internal combustion engine

ABSTRACT

In a system for controlling knocking in an internal combustion engine, a reference value to be compared with a knock sensor signal for determining the presence or absence of the knocking is corrected in accordance with the pattern of a distribution obtained by collecting the logarithmic transformation value of the maximum value of signal generated from the knock sensor signal within a predetermined engine rotational angle at an interval. This is based on the fact that the pattern of distribution represents the characteristic of knocking of the engine.

BACKGROUND OF THE INVENTION

The present invention relates to method and apparatus for controlling aninternal combustion engine to prevent the occurrence of knocking.

Various types of anti-knocking control systems to be incorporated withan internal combustion engine have been developed with a view tominimizing the occurrence of knocking concurrently with maximizing theoutput charactristic of the engine.

Generally, prior art control systems are arranged so as to controlignition timing, air-fuel ratio and the like in accordance with theresults of the comparison of the output signal of a knock sensorattached to the engine and a reference established in advance.

To adjust the balance between the maximization of the outputcharacteristic and the knocking prevention, it is the most importantthat the reference is established adequately in the control, andtherefore a number of attempts to meet this requirement have been madehitherto. Such a technique is disclosed in Japanese Laid-Open PatentApplication No. 56-115861. However, the prior art systems do not producesatisfactory results for meeting demands imposed in high preciseanti-knocking control, because of difficulty of determination of thereference resulting from, for example, mechanical tolerances of engines.

SUMMARY OF THE INVENTION

It is therefore an object of the present invention to provide new methodand apparatus for controlling efficiently an internal combustion engineby properly establishing a reference which is used for determining thepresence or absence of knocking of the engine.

With this and other objects which will be become apparent as thedescription proceeds, an anti-knocking control system according to thepresent invention comprises at least one knock sensor for generating asignal in response to the vibrations of an internal combustion engine,means for determining the presence or absence of knocking by comparingthe knock sensor signal with a reference, means for controlling theengine in accordance with the results of the comparison so as to preventthe occurrence of the knocking, means for repeatedly measuring a maximumvalue of the signal generated by the knock sensor within predeterminedengine rotational angle at an interval thereby obtaining a plurality ofmaximum values, means for computing a logarithmic transformation valueof the measured maximum value, means for deriving a pattern ofdistribution of the plurality of logarithmic transformation values, andmeans for correcting the reference in accordance with the distributionpattern.

According to a feature of the present invention, the reference iscorrected in accordance with a pattern formed by distributing thelogarithmic transformation value of the maximum value of signalgenerated by the knocking sensor within a predetermined enginerotational angle at an interval. This is based on the fact that theshape of the distribution represents the characteristic of thevibrations as will be hereinafter described in detail.

According to a further feature of the present invention, the pattern ofdistribution relative to the logarithmic transformation value of maximumvalue is determined in accordance with the operation performed inrelation to the values with respect to given probability points. Thistechnique takes advantage of the characteristic of the distributionpattern affected by the occurrence condition of knocking and results ina simple anti-knocking control system without logarithmic transformationcircuit.

According to a further feature of the present invention, the knocksensor comprises a microphone for converting the sound emitted from theengine to a corresponding electrical signal. The output signal of themicrophone is supplied, through a band-pass filter for passing onlyfrequency component relative to knocking of the output signals, to apeak-hold circuit for detecting the maximum value. This arrangementmakes it possible to meet the requirements imposed in precise knockingdetection.

BRIEF DESCRIPTION OF THE DRAWINGS

The object and features of the present invention will become morereadily apparent from the following detailed description of thepreferred embodiments taken in conjunction with the accompanyingdrawings in which:

FIG. 1 is a graph showing a frequency distribution patterned inaccordance with the signal having the maximum value of signals generatedby a knock sensor coupled to an internal combustion engine atpredetermined interevals;

FIG. 2 is a cumulative distribution diagram showing the upperprobability integrals with respect to the maximum value of a knocksensor output signal;

FIG. 3 is a graph showing a distribution of the logarithmictransformation value LOG(V) of maximum value with respect to the ratio uof deflection and standard deviation which is derived from the normaldistribution table and the corresponding upper probability integrals;

FIG. 4 illustrates a distribution of the logarithmic transformationvalue of maximum values with respect to the ratio u for a six-cylinderengine;

FIG. 5A is a graph showing a distribution of LOG(V) provided in theabsence of of knocking;

FIG. 5B is a graph illustrating a distribution of LOG(V) obtained whenthe knocking occurs with low frequency;

FIG. 5C is a graph illustrating a distribution of LOG(V) provided whenthe knocking occurs with high frequency;

FIGS. 6A to 6C respectively illustrate a distribution of LOG(V) usefulfor describing the technical basis of the present invention which variesin accordance with the occurring condition of knocking;

FIG. 7 is a schematic block diagram of an anti-knocking control systemaccording to the present invention;

FIG. 8 is a schematic block diagram of an anti-knocking control systemaccording to the present invention incorporated in an intertnalcombustion engine;

FIG. 9 is a schematic block diagram of a peak-hold circuit of ananti-knocking control system according to the present invention;

FIG. 10 is a schematic block diagram of a control unit of ananti-knocking control system according to the present invention;

FIG. 11 is a flow chart of the program provided for the microcomputer ofthe control unit;

FIG. 12 is a flow chart illustrating an example of detailed stepsincluded in the step 103 of the routine of FIG. 11;

FIG. 13 is a flow chart illustrating an example of detailed stepsincluded in the step 109 of the routine of FIG. 11;

FIG. 14 is a flow chart illustrating a second example of detailed stepsincluded in the step 103 of the routine of FIG. 11;

FIG. 15 is a flow chart illustrating a second example of detailed stepsincluded in the step 109 of FIG. 11;

FIG. 16 is a flow chart showing a third example of detailed stepsincluded in the step 109 of FIG. 11;

FIG. 17 is a flow chart describing a further method for correcting areference value used for determining the presence or absence ofknocking.

FIGS. 18A to 18D are schematic block diagrams showing furtheranti-knocking control systems according to the present invention;

FIG. 19a and 19b are a waveform diagram useful for describing thepeak-hold operation;

FIG. 20 is a schematic block diagram showing means for finding thedistribution pattern of the logarithmic transformation value LOG(V)which is incorporated in the control unit;

FIG. 21 is a flow chart illustrating the operation programed forcorrecting the reference in accordance with the comparison of the medianand mean; and

FIG. 22 is a diagram showing a distribution of the logarithmictransformation value of the output signal generated from a microphone.

DETAILED DESCRIPTION OF THE INVENTION

Prior to describing the arrangement of an anti-knocking control systemaccording to the present invention, the technical basis of the inventionwill first be described with reference to FIGS. 1 to 6C.

FIG. 1 illustrates a frequency distribution pattern with respect to themaximum value of signals generated, at an interval, by a knocking sensorcoupled to an internal combustion engine and FIG. 2 is a cumulativedistribution diagram showing the upper probability integrals withrespect to the maximum value of a knock sensor output signal. FIG. 3 isa graph showing a distribution of logarithmic transformation value LOG(V) of the maximum value with respect to the ratio u of a deviation anda standard deviation which ratio is derived from the normal distributiontable. This ratio corresponds to the upper probability integrals of thenormal distribution (%), which will be hereinafter referred to as upperprobability.

The ratio u is defined by the following equation: ##EQU1## where: x=LOG(V)

μ=x, representing the average of LOG (V)

σ=σ(x), representing standard deviation of LOG (V)

In the relationship between the above-mentioned equation and FIG. 3, σrepresents the slope of the line and, if u=0, μ equals to LOG(V).

In FIG. 3, a distribution (a) is obtained when the occurrence of aknocking is absent and a distribution (b) is obtained when the knockingis occured with a certain frequency. Since the distribution (a) is inthe form of a single straight line, it is meant that this distribution(a) is of a normal distribution. On the other hand, since thedistribution (b) is in the form of two straight lines partitioned at apoint of inflexion P, it is meant that this distribution (b) is of acombination of two normal distribution.

The slope of the line (b) up to the point P is approximately equal tothat of the line (a) and the slope beyond the point P becomes greaterthan that of the line (a). The point P moves to the left in the graph asthe frequency of the occurrence of the knocking increases. Therefore,the straight line at the right side beyond the point P represents adistribution of LOG(V) resulting from the occurrence of the knocking. Asa result, it is possible to determine the occurrence condition of theknocking in accordance with the distribution pattern and this is atechnical basis of the present invention.

FIG. 4 illustrates the results of the experiment for a six-cylinderengine. It is seen from the diagram that the distribution pattern is notaffected by the type of engine.

However, this results in a costly apparatus because of using logarithmictransformation means and therefore, to illuminate this problem, it isdesirable to arrange the apparatus without using a logarithmictransformation circuit.

FIG. 5A is a graph showing a distribution of LOG(V) provided in theabsence of knocking. It is understood from FIG. 5A that the followingrelation is made up:

    LOG(V10)-LOG(V50)=LOG(V50)-LOG(V90)

Namely,

    V10/V50=V50/V90                                            (1)

where: V10, V50 and V90 respectively represent the maximum values withrespect to the upper probability of each of 10%, 50% and 90%.

FIG. 5A illustrates a distribution of LOG(V) obtained when the knockingoccurs with low frequency. This condition can also be expressed by theequation (1), however, when the knocking occurs with high frequency asshown in FIG. 5c, the relation is as follows:

    V10/V50>V50/V90                                            (2)

Therefore, it is possible to determine the knocking condition inaccordance with the equations (1) and (2), that is, when the equation(1) is satisfied, the engine is in a too-small-knocking condition,while, it is in a too-much-knocking condition when the equation (2) issatisfied.

V10, V50 and V90 can be obtained as follows.

For computation of the maximum value V10 with respect to the upperprobability 10%, the present maximum value V is first compared with thelast obtained V10. If V>V10, the current V10 is given by the followingequation:

    V10=V10+9×ΔV10

where: ΔV10 represents a constant provided for the upper

side probability 10%,

and if V<V10, the current V10 is obtained by the following equation:

    V10=V10-1×ΔV10

Since the ratio between the amount of variation in V10 in the case ofV>V10 and the same in the case of V<V10 is set to 9 to 1, the currentV10 assumes the value corresponding to an upper probability of 10%.Namely, if V10 is actually the value corresponding to the upperprobability 10%, the probability of V>V10 is 0.1 and that of V<V10 is0.9, and therefore the expectation of the variation of V10 with respectto V is 9×0.1-1×0.9= and the current value V10 is fixed.

On the other hand, if V10 is smaller than the value corresponding to theupper probability 10%, for example, if it is the value with respect tothe upper probability 20%, the probability of V>V10 is 0.2 and that ofV<V10 is 0.8, and therefore the expectation of the variation of V10 is1.8-0.8=1 and V10 varies to the increasing direction so as to assume thevalue corresponding to the upper probability 10%. If V10 is greater thanthe value corresponding to the upper probability 10%, the expectationassumes minus number, and therefore V10 varies to the decreasingdirection so as to assume the value corresponding to the upperprobability 10%.

For the computation of V50, the ratio between the constant for V>V50 andthe constant for V<V50 is established to 1, and for the computation ofV90, the ratio is established to 1/9.

It is desirable that ΔV10, ΔV50 or ΔV90 is established in accordancewith the output of the knock sensor. For example, in the case of theestablishment of V50, ΔV50 is obtained as a mean value using thedifference between V and V50, that is:

    ΔV50=(3×ΔV50+|V-V50|)/4

and if V>V50,

    V50=V50+ΔV50/4

if V<V50,

    V50=V50-ΔV50/4

Using V10, V50 and V90 obtained in the above-mentioned way, V10/V50 andV50/V90 are respectively computed at an interval, for example, every 128cycles to correct the knock-determination reference.

When the knocking occurs with low frequency, since the ratio between V10and V50 scarcely varies in accordance with engine condition or enginetype, it is desirable to correct the knocking determination reference sothat the ratio between V10 and V50 assumes a given value, for example, avalue slightly greater than the ratio between V10 and V50 obtained inthe absence of knocking.

Furthermore, to correct the reference on the basis of the distributionpattern of LOG(V), it is also allowed to utilize the variation of theprobabilities of V>A×V50 and V<V50/A resulting from the presence orabsence of knocking, wherein V50= median and A= constant. FIG. 6Aillustrates a distribution of LOG(V) obtained when the occurrence ofknocking is absent and FIG. 6B shows a distribution of LOG(V) providedwhen the knocking occurs with low frequency. In these conditions, thedistributions have linear patterns within the range of V50/A<V<A×V50 andthus the probability of V>A×V50 is equal to that of V<V50/A.

On the other hand, when knocking frequently occurs, the distribution hasa pattern as shown in FIG. 6C. The probability of V>A×V50 becomesgreater than that of V<V50/A. In this case, the probabilities are 16%and 2%. Namely, the occurring condition of knocking can be checked bymonitoring the probabilities of V>A×V50 and V<V50/A.

Since the probability of V>A×V50 is not affected by engine type or thelike, it is also allowed to correct the reference so as to assume apredetermined frequency value, for example, a value slightly greaterthan the value corresponding to the probability of V>A×V50 obtained whenthe occurrence of knocking is absent.

The basic reference value can be derived from the value with respect toa predetermined probability, for example, it is obtained by K×V50,wherein K= constant.

FIG. 7 is a schematic block diagram of an anti-knocking control systemaccording to the present invention which comprises a knock sensor forgenerating a signal in response to knocking of an engine, means fordetermining the presence or absence of knocking by comparing the signalfrom the knock sensor with a reference, means for controlling the enginethrough a drive means in accordance with the determination to preventthe occurrence of knocking, peak-hold means for detecting the maximumvalue of the signal generated from the knock sensor within apredetermined engine rotational angle at an interval, means formeasuring the pattern of distribution formed in terms of the logarithmictransformation values of the maximum values, and correction means forcorrecting the reference in accordance with the measured distributionpattern.

FIG. 8 is a schematic diagram of an anti-knocking control systemaccording to the present invention incorporated in an internalcombustion engine.

In FIG. 8, a four-cycle four-cylinder internal combustion engine 1 ispartially illustrated and is provided with an intake airflow sensor 3for measuring the flow rate of air taken in through an intake pipehaving an air cleaner 2, a throttle valve 4 and an injector 11 forinjecting fuel into the engine. An ignition distributer 5 is shown asincluding a reference angle sensor 5A which generates a pulseresponsively to a predetermined angular point advanced with respect tothe top dead center and a crank angle sensor 5B which generates a pulsefor every rotation of the engine crankshaft. The ignition distributer 5is associated with an ignitor 10 which is controlled by a signal from acontrol unit 8. Various sensing devices coupled to the engine 1 areprovided for controlling the engine, and include a knock sensor, whichwill be described hereinafter, an engine coolant temperature sensor 9,throttle position sensors 12 and 13, and an oxygen sensor 14 forgenerating a signal indicating that the air-fuel ratio of a mixture iseither on the rich or lean side of stoichiometry. The output signals ofthese sensors are supplied to the control unit 8 and the output signalof the knock sensor 6 is fed thereto through a peak-hold circuit 7.

The peak-hold circuit 7 is illustrated in FIG. 9 to comprise a filter701 for selecting the knocking frequency component from the outputsignal of the knock sensor 6, a amplifier 702 and holding means 703 forholding the maximum value of the signal from the amplifier 702.

The control unit 8 comprising a microcomputer is shown in detail in FIG.10.

The microcomputer includes a central processing unit (CPU) 8000 whichperforms the anti-knocking control in accordance with programmedinstructions stored in a read-only memory (ROM) 8001 and using variousdata necessary for the control stored in a ramdom access memory (RAM)8002. Digital signals to and from the CPU are carried along a common bus8011 to which are coupled the associated units including an interruptcontrol unit 8005 coupled to the reference angle sensor 5A and crankangle sensor 5B through waveform shaping circuits 8003 and 8004 forsupplying an interruption signal. The reference angle sensor 5A is alsocoupled through the waveform shaping circuit 8003 to an 18-bit timer8006 which counts 1-microsecond clock pulses and which is associatedwith the interrupt control unit 8005 for the computation of the enginespeed. A signal indicative of the crankshaft angular position is derivedfrom the output signals of the sensors 5A and 5B, where the signal isused as a cylinder-switching signal for the peak-hold circuit 7. Alsoincluded, in the microcomputer, an A/D converter 8008 for convertion toequivalent digital form from analog signals supplied from the intakeairflow sensor 3, peak-hold circuit 7 and engine temperature sensor 9through a multiplexer 8007. The multiplexer 8007 is controlled by asignal fed through an output port 8010, which is further coupled to thepeak-hold circuit 7, ignitor 10 and injector 11 thereby to control thechange-over of knocking detection among cylinders, ignition timing andair-fuel ratio of a mixture. An input port 8009 is coupled to thethrottle position sensors 12 and 13 and oxygen sensor 14 and the outputsignals thereof are supplied through the bus 8011 to the CPU 8000.

FIG. 11 is a flow chart of the program provided for the microcomputer ofthe control unit 8.

In response to the signal from the interrupt control unit 8005, thisroutine is started from step 100. A subsequent step 101 follows toderive a basic ignition timing from engine condition such as enginespeed Ne, load Q/Ne (Q=intake air amount) and the like. The next step102 is executed to read the maximum value V of knock sensor outputsignal generated within a predetermined period for each cylinder, andcontrol goes to a step 103 which will be described hereinafter.

A subsequent step 104 is provided for checking in accordance with theload and the like whether the engine is in a condition whereanti-knocking control is necessary. If "NO", control jumps to a step 110for setting an ignition timing. If "YES", a step 105 is executed toestablish a reference Vref used for determining the presence or absenceof knocking in accordance with an equation Vref=K×V50. In the next step106, the presence or absence of knocking is determined by comparing Vwith Vref. When V>Vref, a flag is set to logic "H" representing thepresence of knocking and control goes to the next step 107 to derive theretardation amount required for preventing the occurrence of knocking.An ignition timing is computed in a step 108 in accordance with thederived retardation amount.

A subsequent step 109 is provided for correcting the reference whichwill be described hereinafter. After setting the computed ignitiontiming in a step 110, control goes to a return step 111 to return to amain routine.

FIG. 12 is a flow chart illustrating an example of steps included in thestep 103 of the routine of FIG. 11, which is provided for determiningV10, V50 and V90.

In a step X-1, the obtained maximum value V is compared with the lastvalue V10 corresponding to the upper probability 10% which has beenstored in RAM. If V>V10, control goes to a step x-2 to executeV10=V10+9×ΔV10, and if V<V10, a step X-3 is executed so thatV10=V10-ΔV10.

A subsequent step x-4 is provided for checking whether V>V50. If "YES",control goes to a step x-5 to determine V50 by the equationV50=V50+ΔV50, and, if "NO", control advances to a step X-6 to determineV50 by the equation V50=V50-ΔV50.

In a step x-7, V is compared with V90. If V>V90, control goes to a stepx-8 to execute V90=V90+ΔV90 and, if V<V90, a step x-9 is executed asV90=V90-9 ΔV90.

FIG. 13 is a flow chart illustrating an example of steps included in thestep 109 of the routine of FIG. 11, which is provided for correcting theknocing determination reference.

A step x-10 checks in accordance with engine speed Ne and load Q/Newhether the engine is in the normal condition or not. If the engine isnot in the normal condition, control jumps to step x-15, and on theother hand, if the engine is in the normal condition, a subsequent stepx-11 is executed to count the number of cycles, as N=N+1. The next stepx-12 checks whether the normal engine condition continues up to apredetermined number No of cycles or not. If "YES", a step x-13 isexecuted to check whether V10/V50 >V50/V90. If "NO", control goes to thestep 110 of the routine of FIG. 11. In the step x-13, if "YES", controlgoes to a step x-14, and then the reference is established asVref=Vref-ΔV, and if "NO", a step x-15 is executed as Vref=Vref+B×ΔV. Inthe above, "B" is a constant which is set to a value greater than 1. Inthe next step x-16, the counter is reset to zero.

When Vref is increased, the correction value B×ΔV is established so asto become greater than the value ΔV for decreasing Vref. Therefore, Vrefis corrected to the increasing direction.

FIG. 14 is a flow chart illustrating a second example of steps includedin the step 103 of the routine of FIG. 11 for deriving the median V50.

A step Y-1 is provided for deriving a mean value D of the absolute valueof the difference between V50 and V obtained at every one cycle from theequation D=D×3/4+|V-V50|/4. A subsequent step Y-2 checks whether V>V50.If "YES", control goes to a step Y-3 to determine V50 as V50=V50+D/4. If"NO", a step Y-4 is executed to determine as V50=V50-D/4. Therefore, V50assumes a median. Because of using the mean value D of the absolutevalue of the difference between V and V50, when the engine is in atransient state, a sharp variation of V50 is made so that V50 quicklyreaches the median, and on the other hand, when the engine is in thenormal condition, a slight variation is made to stabilize V50.

FIG. 15 is a flow chart illustrating a second example of steps includedin the step 109 of FIG. 11 in which the median V50 is used.

A step Y-5 is provided for checking whether the engine is in the normalcondition or not. If "YES", the cycle counter counts up in a step Y-6 sothat the number of cycles assumes N=N+1. If "NO", control goes to a stepY-17 to initialize various counters.

After the execution of the step Y-6, a step Y-7 follows to check whetherV>A×V50. If "YES", control flows to a step Y-8 to count up as E=E+1 andthe step Y-8 is followed by a step Y-11. A count of counter E isincremented by one when V exceeds A×V50. On the other hand, if "NO",control goes to a step Y-9 to check whether A ×V<V50, and if "Yes", astep Y-10 follows to count up as F=F+1 and then the step Y-11 isexecuted. If "NO" in the step Y-9, the step Y-11 is also executed.

In the step Y-11, it is checked whether the number N of cycle exceeds apredetermined number No or not. If "NO", control goes to the step 110 ofFIG. 11. If "YES", a subsequent step Y-12 follows to check whether thecount E, incremented by one whenever V exceeds A×V50, is greater than apredetermined value E_(MIN). If so, a step Y-13 is executed, and if not,control goes to the step Y-17. Namely, when E<E_(MIN), the knockingdetermination reference is not corrected.

The step Y-13 checks whether E is below a predetermined value E_(MAX).If E is below the predetermined value E_(MAX), the next step Y-14 isexecuted, and if not, control goes to a step Y-15. The step Y-14 checkwhether E-F is greater than a predetermined value G. If "YES", controladvances to the step Y-15, and if "NO", control goes to a step Y-16. Inthe step Y-15, the reference Vref is decreased as Vref=Vref-ΔV, and, inthe step Y-16, Vref is increased by ΔV. After the execution of the stepY-15 or Y16, the step Y-17 which is followed by the step 110 of FIG. 11is executed to initialize each counter.

As described above, if "NO" in the step Y-13, the reference Vref isreduced irrespective of the determination of the step Y-14. This isbased on the fact that the value E assumes an extremely great value whenthe knocking occurs with high frequency. In the step Y-14, E-F iscompared with a threshold value G greater than zero. This is executedfor the purpose of correcting or increasing the reference value Vrefwhen the knocking occurs with low frequency. Generally, A assumes 2.

FIG. 16 is a flow chart illustrating a third example of steps includedin the step 109 of FIG. 11.

In this case, the reference Vref is determined as Vref=K×V50 and the Kis corrected in accordance with the probability of V>Vref and theprobability of V<V50/K.

A step Z-5 is provided for checking whether the engine is in the normalcondition or not. If "NO", control goes to the step 110 of FIG. 11. If"YES", the next step Z-6 is executed to check whether the knock flag hasbeen set to logic "H", that is, whether V>K×V50. If "YES" in the stepZ-6, control flows to a step Z-7 and, if "NO", a step Z-10 is executed.In the step Z-7, K is decreased as K=K-Δ1, and the next step Z-8 followsto check whether K is below a predetermined value K_(MIN) or not. If Kis below the predetermined value, control goes to a step Z-9 toestablish K to K_(MIN). If not, control goes to the step 110 of FIG. 11.

The step Z-10 is provided for checking wether K×V<V50. If "NO", controlgoes to the step 110 of the routine of FIG. 11. If "YES", a subsequentstep Z-11 is executed to increase K by Δ2. The next step Z-12 checkswhether K exceeds a predetermined value K_(MAX) or not. If "NO", controlgoes to the step 110 of the routine of FIG. 11. On the other hand, if"YES", a step Z-13 follows to establish K as K_(MAX).

The correction value Δ2 in the step Z-11 is set to be slightly greaterthan the correction value Δ1 in the step Z-7. For example, Δ1=1/32 andΔ2=1/16. When knocking occurs with low frequency, the probability ofV>K×V50 is equal to the probability of V<V50/K. In this case, however,the reference is corrected so as to become greater than before.Generally, the intial value of K is 2.

FIG. 17 is a flow chart describing further operation for correcting areference value used for determining the presence or absence ofknocking.

In the above-mentioned routine for correcting the reference level, ifV>A×V50, the reference level is decreased, and if V<V50/A, it isincreased. However, it is desirable that A is also varied in accordancewith the distribution pattern and this results in more preciseanti-knocking control.

In the routine shown in FIG. 17, a step Y-30 is provided for checkingwhether V>V50. If "YES", control goes to a step Y-40 to check whetherV>A×V50. If "YES" in the step Y-40, a step Y-50 is executed to increaseA as A =A+ΔA (K is decreased). If "NO" in the step Y-40, control goes toa step Y-80. On the other hand, in the step Y-30, if "NO", control goesto a step Y-60 to check whether V<V50/A. If "YES" in the step Y-60, astep Y-70 is executed to increase A in the same manner (K is alsoincreased). If "NO" in the step Y-60, control goes to the step Y-80.

In the step Y-80, when the step Y-40 or Y-60 is not in the condition ofV>A×V50 or V<V50/A during n ignition cycles, A is reduced by ΔA in thenext step Y-90.

Assuming that n is 8, the reference value approximately assumes thevalue corresponding to the upper probability 95%. Accordingly, theprobability of the occurrence of knocking assumes 5%.

FIGS. 18A to 18D are schematic block diagrams showing furtheranti-knocking control systems according to the present invention.

The anti-knocking system shown in FIG. 18A is arranged to control thereference or engine control factor such as ignition timing in accordancewith a signal from the correction means and includes a peak-hold circuithaving a logarithmic transformation circuit. The anti-knocking controlsystem shown in FIG. 18B is arranged to directly control the enginecontrol factor in accordance with the signal from the correction meanswithout correcting the reference. The control system illustrated in FIG.18C includes means for limiting the control value to a predeterminedrange, and the reference value for the limitation is corrected inaccordance with a signal from the correction means. Furthermore, thecontrol system illustrated in FIG. 18C has means for producing the meanvalue of the output signals generated by the knock sensor and means forobtaining the logarithmic transformation of the mean value of the outputsignals.

FIG. 19 is a waveform diagram useful for describing the peak-holdoperation. In FIG. 19, signal (a) is the output signal of the knocksensor and signal (b) is the logarithmic transformation signal of theoutput signal. The references v1 and v2 of the signal (b) represent thelogarithmic transformation values corresponding to the maximum values V1and V2 of the signal (a), and these signals are supplied to the controlunit as peak-hold signals. The peak-hold circuit 7 is controlled by thecontrol unit 8 so as to perform the peak-hold operation at intervals of10°CATDC to 90°CATDC.

FIG. 20 is a schematic block diagram showing means for finding thedistribution pattern of the logarithmic transformation value LOG(V)where the means is incorporated in the control unit.

In FIG. 20, the peak-hold signal is supplied to a knocking determinationcircuit, median computing circuit and mean value computing circuitthrough lines 20, 30 and 40. The derived median is used for establishinga knocking determination reference, and the output signal of the mediancomputing circuit is supplied to a comparison circuit through a line 60to correct the reference. The reference value is determined bymultiplying the median value by a constant K. On the other hand, thederived mean value is compared with the median value fed through theline 60, and in accordance with the results of the comparison, theconstant K is increased or decreased to correct the reference value.Namely, this is a method for correcting the reference value inaccordance with the comparison between the median and mean.

FIG. 21 is a flow chart illustrating the operation programed forcorrecting the reference in accordance with the comparison between themedian and mean.

A step 201 is provided for deriving a basic ignition timing from enginespeed, intake air pressure and the like, and the next step 202 isprovided for determining the presence or absence of knocking bycomparing a knock sensor signal with a reference value. This referencevalue is established by multiplying the median v50 of a distribution ofLOG(V), i.e., the value of cumulative distribution 50%, by a constant K.In a subsequent step 203, if the engine is in the knocking condition, astep 204 is executed to additionally retard the basic ignition timing byΔR (generally, about 0.5 to 1°CA). If not, a step 205 is executed toreduce a retardation value R by ΔR (R=R-ΔR) when the number of ignitionswithout knocking exceeds a predetermined value and to maintain theretardation value R when it does not exceed.

A subsequent step 206 is provided for updating the median. Assuming thatcharacter M represents the actual median and v50 represents a medianobtained by computation, then v50 is increased by Δv50 when an inputsignal v is greater than v50, and on the other hand, v50 is decreased byΔv50 when the input signal v is less than v50. Since the probability ofa value smaller than the median is equal to the probability of a valuegreater than the median, that is, they are both 50%, if v50=M, theprobability of v>v50 is equal to the probability of v<v50. However, ifv50 is smaller than M, the probability of v>v50 is increased andtherefore the frequency of increasing V50 by ΔV50 becomes high, and onthe other hand, if v50>M, the probability of V<V50 is increased andtherefore the frequency of decreasing v50 by Δv50 becomes high.Accordingly v 50 approaches the actual median M as v50 is updatedrepeatedly. This method just requires a simple construction having onlyone RAM. In this case, however, the median, mean value and referencevalue are respectively established per cylinder for performing moreaccurately determination of knocking condition. Therefore, a pluralityof RAMs as many as the number corresponding to the number of cylindersmay be required.

A step 207 is provided for updating the mean value of input signals v(=LOG V). The mean value can be established in accordance with a wellknown method, for example the median v may be obtained every ignition byan equation v=(7 v+v)/8.

A subsequent step 208 is executed to compare the mean value v with themedian v50. In the next step 209, if v≧B ×v50 (B=a constant, about 1.1),a step 210 is executed, and if v<B×v50, control goes to a step 212.Namely, the step 210 is executed when the knocking occurs with highfrequency. When v≧B×v50, the current reference value is too great,resulting in difficult detection. When this condition has been continuedover a predetermined period of time, the constant K is reduced to lowerthe reference level. This results in the correction of the suitablereference level caused by the error of computation. Furthermore in thestep 210, the correction is not performed when the engine is in thetransient condition so as to accurately check the presence or absence ofknocking.

A subsequent step 211 is provided for reducing the reference valueconcurrently with retarding the ignition timing when the reference levelis too high. Namely, when the too-high reference level has been found,the engine is already in the knocking condition and therefore it isrequired to retard the ignition timing. This also results in thepreventation of overshooting and undershooting of the referencecorrection. Furthermore in the step 210, when the retardation valuereaches a predetermined maximum value, the limitation or the maximumretardation value is lightened. Namely, the maximum retardation valueRmax is further retarded as necessary to meet the requirements of theanti-knocking control.

In the step 209, if v<B×v50, control goes to steps 212 and 213 toincrease the reference value and to advance the ignition timing.However, in the step 212, when the retardation value R is approximatelyzero, the reference is not increased.

A subsequent step 214 is provided for newly determining a referencevalue by multiplying the corrected K by the updated v50. This referenceis determined for every cylinder and used for determining the presenceor absence of knocking in the following ignition cycle. In the next step215, an ignition timing is derived from the retardation value and basicignition timing.

Turning back to FIG. 8, generally, the sensor of piezoelectric type orelectromagnetic type is used as a knock sensor 6 for measuringvibrations of the engine. However, in this case, because the sensor 6 isattached to the engine as shown in the diagram, a plurality of sensorsare required to meet the requirements imposed in precise knockingdetection. A reason for this is that the vibrations of the portionsremote from the sensor cannot be detected completely. This results in acostly system and therefore attempts to use a microphne as a knockingsensor have been made as is described in Japanese Laid-open ApplicationNo. 51-46606. However, due to the reduction of S/N ratio, it has notbeen perfected to the point where it can be utilized in theapplications. Now, this problem is eliminated by employing themicrophone for the above-mentioned anti-knocking control systemaccording to the present invention. FIG. 22 is a distribution diagramwith respect to the maximum value of signal obtained from themicrophone. It is seen from the diagram that the microphone is usefulfor the anti-knocking control.

It should be understood that the foregoing relates to only preferredembodiments of the invention, and that it is intended to cover allchanges and modifications of the embodiments of the invention hereinused for the purposes of the disclosure, which do not constitutedepartures from the spirit and scope of the invention. For example,although in the foregoing description the logarithmic transformation isperformed using a logarithmic transformation circuit, the sametransformation can be effected using a logarithmic transformation tablestored in the ROM of the microcomputer. Furthermore, although thedistribution pattern of LOG(V) is checked to correct a reference value,however, it is also possible to correct the same in accordance with thedistribution pattern of LOG Vmean, wherein Vmean = the mean value ofknock sensor signals.

What is claimed is:
 1. Apparatus for controlling knocking in an internalcombustion engine, comprising:(a) a knock sensor for generating a signalin response to the vibrations in said engine; (b) means for determiningthe presence of knocking by comparing said knock sensor signal with areference; (c) means for controlling said engine to prevent saidknocking in accordance with the determination; (d) means for measuring amaximum value of said knock sensor signal generated within apredetermined engine rotational angle at an interval thereby obtaining aplurality of maximum values; (e) means for determining a pattern ofdistribution of a plurality of logarithmic values corresponding to saidplurality of maximum values; and (f) means for correcting said referencein accordance with said distribution pattern.
 2. Apparatus as claimed inclaim 1, wherein said knocking sensor comprises a microphone forconverting a sound emitted from said engine to a correspondingelectrical signal and a band-pass filter for passing only frequencycomponent relating to knocking of said knock sensor signal.
 3. Apparatusas claimed in claim 1, wherein said engine control means comprises meansfor controlling the ignition timing of said engine.
 4. Apparatus asclaimed in claim 1, wherein said engine control means comprises meansfor controlling the air-fuel ratio of mixture to be supplied to saidengine.
 5. Apparatus as claimed in claim 1, wherein said reference isinitially established by multiplying a value corresponding to a givenprobability in said distribution by a predetermined value.
 6. Apparatusas claimed in claim 5, wherein said value is the median of saiddistribution.
 7. Apparatus for controlling knocking in an internalcombusion engine, comprising:(a) a knock sensor for generating a signalin response to the vibrations in said engine; (b) means for determiningthe presence of knocking by comparing said knock sensor signal with areference; (c) means for controlling said engine to prevent saidknocking in accordance with the determination; (d) means for measuring amaximum value of said knock sensor signal generated within apredetermined engine rotational angle at an interval thereby obtaining aplurality of maximum values; (e) means for measuring first to thirdvalues corresponding to first to third probability points in acumulative distribution of said plurality of maximum values; (f) meansfor computing a first ratio between said first and second values; (g)means for computing a second ratio between said second and third values;(h) means for comparing said first ratio with said second ratio; and (i)means for correcting said reference in accordance with the results ofthe comparison.
 8. Apparatus as claimed in claim 7, wherein saidreference is initially established by multiplying a value correspondingto a given probability in said distribution by a predetermined value. 9.Apparatus for controlling knocking in an internal combusion engine,comprising:(a) a knock sensor for generating a signal in response to thevibrations in said engine; (b) means for determining the presence ofknocking by comparing said knock sensor signal with a reference; (c)means for controlling said engine to prevent said knocking in accordancewith the determination; (d) means for measuring a maximum value of saidknock sensor signal generated within a predetermined engine rotationalangle at an interval thereby obtaining a plurality of maximum values;(e) means for measuring first and second values corresponding to firstand second probability points in a cumulative distribution of saidplurality of maximum values; (f) means for computing the ratio betweensaid first and second values; and (g) means for correcting saidreference so that said ratio assumes a predetermined value. 10.Apparatus as claimed in claim 9, wherein said reference is initiallyestablished by multiplying a value corresponding to a given probabilityin said distribution by a predetermined value.
 11. Apparatus forcontrolling knocking in an internal combusion engine, comprising:(a) aknock sensor for generating a signal in response to the vibrations insaid engine; (b) means for determining the presence of knocking bycomparing said knock sensor signal with a reference; (c) means forcontrolling said engine to prevent said knocking in accordance with thedetermination; (d) means for measuring a maximum value of said knocksensor signal generated within a predetermined engine rotational angleat an interval thereby obtaining a plurality of maximum values; (e)means for measuring a value corresponding to a predetermined probabilitypoint in a cumulative distribution of said plurality of maximum values;(f) means for obtaining a value by multiplying said measured value by aconstant; and (g) means for correcting said reference so that themaximum value of said knock sensor signal exceeds said obtained valuewith predetermined frequency.
 12. Apparatus as claimed in claim 11,wherein said reference is initially established by multiplying a valuecorresponding to a given probability in said distribution by apredetermined value.
 13. Apparatus for controlling knocking in aninternal combusion engine, comprising:(a) a knock sensor for generatinga signal in response to the vibrations in said engine; (b) means fordetermining the presence of knocking by comparing said knock sensorsignal with a reference; (c) means for controlling said engine so as toprevent the knocking in accordance with the determination; (d) means formeasuring the maximum value of said knock sensor signal generated withina predetermined engine rotational angle at an interval thereby obtaininga plurality of maximum values; (e) means for measuring a median of acumulative distribution of said plurality of maximum values; (f) meansfor comparing said maximum value with said median multiplied by aconstant; (g) means for comparing said maximum value with said mediandivided by said constant; and (h) means for correcting said reference inaccordance with the results of the comparisons.
 14. Apparatus as claimedin claim 10, said correction means is operated only when said engine isin a stable condition.
 15. Apparatus as claimed in claim 13, whereinsaid constant is determined in accordance with said results ofcomparisons.
 16. Apparatus as claimed in claim 15, wherein said constantis increased when said maximum value is greater than said medianmulitiplied by said constant.
 17. Apparatus as claimed in claim 15,wherein said constant is increased when said maximum value is smallerthan said median divided by said constant.
 18. Apparatus as claimed inclaim 15, wherein said constant is decreased when said maximum value iscontinuously smaller than said median multiplied by said constant over aperiod of time corresponding to a predetermined number of ignitions. 19.Apparatus as claimed in claim 15, wherein said constant is dereased whensaid maximum value is continuously greater than said median divided bysaid constant over a period of time corresponding to a predeterminednumber of ignitions.
 20. Apparatus for controlling knocking in aninternal combusion engine, comprising:(a) a knock sensor for generatinga signal in response to the vibrations in said engine; (b) means fordetermining the presence of knocking by comparing said knock sensorsignal with a reference; (c) means for controlling said engine toprevent knocking in accordance with the determination; (d) means forperforming logarithmic transformation of said knock sensor signalgenerated within a predetermined engine rotational angle at an intervalthereby obtaining a plurality of logarithmic transformation signals; (e)means for measuring a maximum value of each of said plurality oflogarithmic transformation signals; (f) means for obtaining the medianin a distribution of said plurality of maximum values; (g) means forobtaining the mean of said plurality of maximum values; (h) means forcomparing said obtained median with said obtained mean; and (i) meansfor correcting said reference in accordance with the results of thecomparison.
 21. Apparatus for controlling knocking in an internalcombustion engine, comprising:(a) a knock sensor for generating a signalin response to the vibrations in said engine; (b) means for determiningthe presence of knocking by comparing said knock sensor signal with areference; (c) means for controlling said engine to prevent knocking inaccordance with the determination; (d) means for measuring a maximumvalue of said knock sensor signal generated within a predeterminedengine rotational angle at an interval thereby obtaining a plurality ofmaximum values; (e) means for performing logarithmic transformation ofsaid plurality of maximum values; (f) means for obtaining a median of adistribution of said plurality of logarithmic transformation values; (g)means for obtaining a mean value of said plurality of maximum values;(h) means for comparing said obtained median with said obtained meanvalue; and (i) means for correcting said reference in accordance withthe results of the comparison.
 22. Apparatus for controlling knocking inan internal combustion engine, comprising:(a) a knock sensor forgenerating a signal in response to the vibrations in said engine; (b)means for performing logarithmic transformation of said knock sensorsignal generated within a predetermined engine rotational angle at aninterval thereby obtaining a plurality of logarithmic transformationsignals; (c) means for measuring a maximum value of each of saidplurality of logarithmic transformation s:gnals; (d) means for derivinga pattern of distribution of a plurality of maximum values; and (e)means for controlling the ignition timing of said engine in accordancewith said distribution pattern.
 23. Apparatus for controlling knockingin an internal combustion engine, comprising:(a) a knock sensor forgenerating a signal in response to the vibrations in said engine; (b)means for controlling a value relating to the ignition timing of saidengine so as not to exceed a reference level; (c) means for performinglogarithmic transformation value of said knock sensor signal generatedwithin a predetermined engine rotation angle at an interval therebyobtaining a plurality of logarithmic transformation signals; (d) meansfor measuring a maximum value of each of said plurality of logarithmictransformation signals; and (e) means for controlling said referencelevel in accordance with a pattern of distribution of said plurality ofmaximum values.
 24. Apparatus for controlling knocking in an internalcombustion engine, comprising:(a) a knock sensor for generating a signalin response to the vibrations in said engine; (b) means for determiningthe presence of knocking by comparing said knock sensor signal with areference; (c) means for detecting the condition of said engine; (d)means for controlling said engine in accordance with said determinationand said detected engine condition; (e) means for deriving a mean valueof said knock sensor signals generated within a predetermined enginerotational angle at an interval thereby obtaining a plurality of meanvalues; (f) means for obtaining logarithmic transformation value of eachof said plurality of mean values derived; and (g) means for controllingsaid reference and the ignition timing of said engine in accordance witha pattern of distribution of said plurality of logarithmictransformation values.
 25. A method for controlling knocking in aninternal combustion engine, comprising the steps of:(a) obtaining asignal indicative of engine vibrations produced by a knock sensor; (b)determining the presence of knocking by comparing said knock sensorsignal with a reference; (c) controlling said engine to prevent theknocking in accordance with the determination; (d) measuring a maximumvalue of said knock sensor signal generated within a predeterminedengine rotational angle at an interval thereby obtaining a plurality ofmaximum values; (e) deriving a pattern of distribution of said pluralityof logarithmic values corresponding to said plurality of maximum values;and (f) correcting said reference in accordance with said distributionpattern.
 26. A method for controlling knocking in an internal combustionengine, comprising the steps of:(a) obtaining a signal indicative ofengine vibrations using a knock sensor; (b) determining the presence ofknocking by comparing said knock sensor signal with a reference; (c)controlling said engine to prevent knocking in accordance with thedetermination; (d) measuring a maximum value of said knock sensor signalgenerated within a predetermined engine rotational angle at an intervalthereby obtaining a plurality of maximum values; (e) measuring first tothird values corresponding to first to third probability points in acumulative distribution of said plurality of maximum values; (f)computing a first ratio between said first and second values; (g)computing a second ratio between said second and third values; (h)comparing said first ratio with said second ratio; and (i) correctingsaid reference in accordance with the results of the comparison.
 27. Amethod for controlling knocking in an internal combustion engine,comprising the steps of:(a) obtaining a signal indicative of enginevibrations using a knock sensor; (b) determining the presence ofknocking by comparing said knock sensor signal with a reference; (c)controlling said engine to prevent the knocking in accordance with thedetermination; (d) measuring a maximum value of said knock sensor signalgenerated within a predetermined engine rotational angle at an intervalthereby obtaining a plurality of maximum values; (e) measuring first andsecond values corresponding to first and second probability points in acumulative distribution of said plurality of maximum values; (f)computing the ratio between said first and second values; and (g)correcting said reference so that said ratio assumes a predeterminedvalue.
 28. A method for controlling knocking in an internal combustionengine, comprising the steps of:(a) obtaining a signal indicative ofengine vibrations using a knock sensor; (b) determining the presence ofknocking by comparing said knock sensor signal with a reference; (c)controlling said engine to prevent the knocking in accordance with thedetermination; (d) measuring the maximum value of said knock sensorsignal generated within a predetermined engine rotational angle at aninterval thereby obtaining a plurality of maximum values; (e) measuringa value corresponding to a predetermined probability point in acumulative distribution of said plurality of maximum values; (f)obtaining a value by multiplying said measured value by a constant; and(g) correcting said reference so that the maximum value of said knocksensor signal exceeds said obtained value with predetermined frequency.29. A method for controlling knocking in an internal combustion engine,comprising the steps of:(a) obtaining a signal indicative of enginevibrations using a knock sensor; (b) determining the presence ofknocking by comparing said knock sensor signal with a reference; (c)controlling said engine to prevent the knocking in accordance with thedetermination; (d) measuring the maximum value of said knock sensorsignal generated within a predetermined engine rotational angle at aninterval thereby obtaining a plurality of maximum values; (e) measuringthe median of a cumulative distribution of said plurality of maximumvalues; (f) comparing said maximum value with said median multiplied bya constant; (g) comparing said maximum value with said median divided bysaid constant; and (h) correcting said reference in accordance with theresults of the comparisons.
 30. A method for controlling knocking in aninternal combustion engine, comprising the steps of:a) obtaining asignal indicative of engine vibrations using a knock sensor; (b)determining the presence of knocking by comparing said knock sensorsignal with a reference; (c) controlling said engine to prevent theknocking in accordance with the determination; (d) performinglogarithmic transformation of said knock sensor signal generated withina predetermined engine rotational angle at an interval thereby obtaininga plurality of logarithmic transformation signals; (e) measuring amaximum value of each of said plurality of logarithmic transformationsignals; (f) obtaining the median in a distribution of said plurality ofmaximum values; (g) computing a mean value of said maximum values; (h)comparing said obtained median with said computed mean; and (i)correcting said reference in accordance with the results of thecomparison.